import router from './router'
import NProgress from 'nprogress'
import 'nprogress/nprogress.css'

router.beforeEach(async(to, from, next) => {
  NProgress.start()
  NProgress.configure({ parent: '.main-content', showSpinner: false })
  next()
  NProgress.done()
})

router.afterEach(() => {
  NProgress.done()
})
